<template>
  <div>
    <product
      v-for="item in list"
      :key="item.id"
      :title="item.proname"
      :pri="item.proprice"
      :inof="item.uname"
      :id="item.id"
      @harry="harryFn"
    />
  </div>
</template>

<script>
import product from './components/product.vue'
export default {
  components: { product },
  data() {
    return {
      list: [
        { id: 1, proname: '超级好吃的棒棒糖', proprice: 18.8, uname: '你好啊' },
        {
          id: 2,
          proname: '超级好吃的大鸡腿',
          proprice: 34.2,
          uname: '你好啊嘛',
        },
        {
          id: 3,
          proname: '超级无敌的冰激凌',
          proprice: 14.2,
          uname: '你好啊了',
        },
      ],
    }
  },
  methods: {
    harryFn(id) {
      console.log('harryFn触发了', id)
    },
  },
}
</script>

<style></style>
